package com.zzyl.mapper;

import com.github.pagehelper.Page;
import com.zzyl.dto.UserDto;
import com.zzyl.entity.User;
import com.zzyl.vo.UserVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface UserMapper {
    List<UserVo> selectPage(UserDto userDto);

    void insert(User user);

    void update(User user);

    @Select("select * from sys_user where id =#{userId}")
    User getById(Long userId);
    @Select("select * from sys_user where username =#{username}")
    User selectByName(String username);
}
